package com.lyz.javabean;

/**
 * @ClassName GameDemo
 * @Description 学生类使用
 * @Author 2214361854
 * @Date 2022/2/12 21:50
 * @Version 1.0
 */
public class Test {
    public static void main(String[] args) {
        Student s1 = new Student();
        s1.setName("小明");
        s1.setSex('男');
        s1.setHobby("学习");
        s1.study();
        System.out.println(s1);

        Student s2 = s1;
        System.out.println(s2);
        s2.study();
        s2.setName("小王");
        s1.study();
    }
}
